

message(STATUS "\n----------From MyWork/CMakeLists.txt----------")

#find_package(MPI REQUIRED)
#FIND_PACKAGE(Boost COMPONENTS mpi serialization REQUIRED)

message(STATUS "Base include directories: ${ATOMISM_BASE_INCLUDE_DIRS}")
message(STATUS "Base libraries: ${ATOMISM_BASE_LIBRARIES}")
message(STATUS "Molecule include directories: ${ATOMISM_MOLECULE_INCLUDE_DIRS}")
message(STATUS "Molecule libraries: ${ATOMISM_MOLECULE_LIBRARIES}")
message(STATUS "Math include directories: ${ATOMISM_MATH_INCLUDE_DIRS}")
message(STATUS "Math libraries: ${ATOMISM_MATH_LIBRARIES}")
message(STATUS "Bayes include directories: ${ATOMISM_BAYES_INCLUDE_DIRS}")
message(STATUS "Bayes libraries: ${ATOMISM_BAYES_LIBRARIES}")
#message(STATUS "MPI include directories: ${MPI_INCLUDE_PATH}")
#message(STATUS "MPI libraries: ${MPI_LIBRARIES}")

INCLUDE_DIRECTORIES( ${ATOMISM_BASE_INCLUDE_DIRS} 
		     ${ATOMISM_MOLECULE_INCLUDE_DIRS}
		     ${ATOMISM_MATH_INCLUDE_DIRS}
		     ${ATOMISM_BAYES_INCLUDE_DIRS}
		     #${MPI_INCLUDE_PATH} 
		     )

FILE(GLOB MYWORKS_SRC     ${CMAKE_CURRENT_SOURCE_DIR}/src/*.cpp )
FILE(GLOB MYWORKS_HEADER  ${CMAKE_CURRENT_SOURCE_DIR}/src/*.h )

add_library ( mywork   SHARED ${MYWORKS_SRC} 
			      launcher.cpp
             )
          
SET_TARGET_PROPERTIES( mywork PROPERTIES COMPILE_FLAGS -fPIC )
SET_TARGET_PROPERTIES( mywork PROPERTIES COMPILE_FLAGS -O3 )

TARGET_LINK_LIBRARIES( mywork ${ATOMISM_BASE_LIBRARIES} 
		              ${ATOMISM_MOLECULE_LIBRARIES} 
			      ${ATOMISM_MATH_LIBRARIES} 
			      ${ATOMISM_BAYES_LIBRARIES} 
                      )
IF( COVERAGE )
TARGET_LINK_LIBRARIES( mywork gcov)
ENDIF( COVERAGE )
SET( ATOMISM_MYWORK_INCLUDE_DIRS  ${CMAKE_CURRENT_SOURCE_DIR}/src 
     #${MPI_INCLUDE_PATH}  
     )
SET( ATOMISM_MYWORK_LIBRARIES     mywork   )

#ADD_SUBDIRECTORY( ${CMAKE_CURRENT_SOURCE_DIR}/diatomic_potential/N4 )


